﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace FantastPlatform.Decision.UI
{
    public partial class SSLIdentification : BasePage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            string userSubjectCN = Request.ClientCertificate["SubjectCN"];
            if (string.IsNullOrEmpty(userSubjectCN))
            {
                Response.Redirect("Error.aspx");
            }
            else
            {
                string[] userInfo = userSubjectCN.Split(' ');
                string idCard = userInfo[userInfo.Length - 1];
                Response.Redirect("http://10.65.81.20:8084/login.aspx?idCard=" + idCard);
            }
        }
    }
}